Skip to content

[Refactor]: replace ai-assistant model config file with ts for npm availability - #3154

Merged
igorDykhta merged 1 commit into
keplergl:masterfrom
holahmide:refactor/json-to-ts-config
Jul 10, 2025
Merged

[Refactor]: replace ai-assistant model config file with ts for npm availability#3154
igorDykhta merged 1 commit into
keplergl:masterfrom
holahmide:refactor/json-to-ts-config

Conversation

@holahmide

Copy link
Copy Markdown
Contributor

Context

The new AI-assistant feature added a runtime import of config/models.json. While the file exists in the repository, it is excluded from the published npm package, so any downstream project (npm install kepler.gl) fails to build with:

Module not found: Error: Can't resolve 'config/models.json'

Screenshot 2025-07-08 at 17 38 23

What this PR does?

Replaces config/models.json with a strongly-typed config/models.ts module.

Updates all imports to reference the new TypeScript file (import models from 'config/models').

@igorDykhta
igorDykhta requested a review from lixun910 July 9, 2025 00:11
@lixun910

lixun910 commented Jul 9, 2025

Copy link
Copy Markdown
Collaborator

Thank you, @holahmide ! The solution looks good to me. Can you solve the conflicts since there is an updated models.json file: https://github.com/keplergl/kepler.gl/blob/master/src/ai-assistant/src/config/models.json? Let me know if you need any assistance.

…ailability

Signed-off-by: Olamide Adeniyi <olami02bj@gmail.com>
@holahmide
holahmide force-pushed the refactor/json-to-ts-config branch from 98d5b19 to daa2892 Compare July 9, 2025 01:03
@holahmide

Copy link
Copy Markdown
Contributor Author

Thanks @lixun910! I have fixed the conflicts.

@igorDykhta
igorDykhta merged commit d43e8bb into keplergl:master Jul 10, 2025
7 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants